/**
 * 给定国际象棋两格，问是否同色
 */
class Solution {
public:
    bool checkTwoChessboards(string coordinate1, string coordinate2) {
        int x1 = coordinate1[0] - 'a' + 1;
        int y1 = coordinate1[1] - '0';
        int x2 = coordinate2[0] - 'a' + 1;
        int y2 = coordinate2[1] - '0';

        int t1 = (x1 + y1) & 1;
        int t2 = (x2 + y2) & 1;
        return t1 == t2;
    }
};